from postgresql import PostgreSQL
from dbapi import *

class Database:
	def __init__(self):
		self.sql = PostgreSQL()
		self.sql.connect('localhost', 'str', '', 'str')
		self.sql.setDict(True)
		pass

	def loadRows(self, query, params = []):
		return self.sql.loadRows(query, params)

	def loadRow(self, query, params = []):
		return self.sql.loadRow(query, params)

	def loadValue(self, query, params = []):
		return self.sql.loadValue(query, params)

	def getAccount(self, user, password):
		return self.sql.loadRow(SQL_GET_ACCOUNT, [user, password])
